<!--加载中组件-->
<template>
  <a-spin size="large" :tip="'加载中...'" :spinning="isLoading" :delay="100" />
</template>

<script lang="ts" setup>
import { ref, watch } from 'vue'
import { userStore } from '../../store/index'
const store = userStore()
const isLoading = ref<Boolean>(store.getRequestLoadState)
// 监听状态，实时改变
watch(store, () => {
  isLoading.value = store.getRequestLoadState
})
</script>

<style scoped lang="scss"></style>
